Socket
Socket
Sign inDemoInstall

react-emotion

Package Overview
Dependencies
4
Maintainers
2
Versions
73
Alerts
File Explorer

Advanced tools

Install Socket

Detect and block malicious and high-risk dependencies

Install

react-emotion

The Next Generation of CSS-in-JS, for React projects.


Version published
Weekly downloads
44K
increased by15.49%
Maintainers
2
Created
Weekly downloads
 

Readme

Source

react-emotion

The styled API for emotion and react

react-emotion exports styled which allows you to use emotion to create React components that have styles attached to them, it also exports all of emotion's exports.

For more documentation on styled, read about it and try it out in the styled docs

npm install --save emotion react-emotion
// @live
import styled, { css } from 'react-emotion'
const SomeComponent = styled('div')`
  display: flex;
  background-color: ${props => props.color};
`

const AnotherComponent = styled('h1')(
  {
    color: 'hotpink'
  },
  props => ({ flex: props.flex })
)

render(
  <SomeComponent color="#DA70D6">
    <AnotherComponent flex={1}>Some text.</AnotherComponent>
  </SomeComponent>
)

Keywords

FAQs

Last updated on 30 Sep 2018

Did you know?

Socket

Socket for GitHub automatically highlights issues in each pull request and monitors the health of all your open source dependencies. Discover the contents of your packages and block harmful activity before you install or update your dependencies.

Install

Related posts

SocketSocket SOC 2 Logo

Product

  • Package Alerts
  • Integrations
  • Docs
  • Pricing
  • FAQ
  • Roadmap

Packages

Stay in touch

Get open source security insights delivered straight into your inbox.


  • Terms
  • Privacy
  • Security

Made with ⚡️ by Socket Inc